// ./mock/message/index.js

import { Flash } from "@vicons/ionicons5";
import Mock from "mockjs";
const Random = Mock.Random;

// 生成数据消息并赋值给 data 字段
const ruleList = Mock.mock({
  "data|88": [{ //产生 30 条记录 
    "id|+1": 1, //id 号从 1 开始连续编号 
    "ruleName": "@cname", //规则名称
    "ruleType|1": ['空值检查', '枚举检查', '脚本检查', '值域检查'], //规则类型
    "topicTable": "ACT_GE_PROPERTY",
    "checkField": "姓名、性别",
    "etlPackage": "门诊就诊表数据采集",
    "status|1-2": true,
    "creator": "@cname",
    "createTime": "@date('yyyy-MM-dd HH:mm:ss')",
    "description": "@csentence(10,20)" //10-20字的句子
  }]
})

export function getRuleList() {
  return {
    code: 200,
    data: ruleList.data,
  }
}
export function postRuleList(){
  return {
    code: 200,
    data: [],
    message:"添加成功",
    success:true,
  }
}
export function deleteRuleList(){
  return {
    code:200,
    data:[],
    message:'删除成功',
    success:true,
  }
}
